﻿using MemberManagement.Entity.Enum;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace MemberManagement.Model
{
    public class RechargeQueryModel
    {
        /// <summary>
        /// 主键id
        /// </summary>
        public int Id { get; set; }
        /// <summary>
        /// 会员id
        /// </summary>
        public string MemberName { get; set; }
        /// <summary>
        /// 充值金额
        /// </summary>
        public decimal Amount { get; set; }
        /// <summary>
        /// 余额
        /// </summary>
        public decimal Balance { get; set; }
        /// <summary>
        /// 类型
        /// </summary>
        public RechargeType_Enum Type { private get; set; }

        /// <summary>
        /// 创建时间
        /// </summary>
        public System.DateTime CreateTime { get; set; } = new DateTime();

        /// <summary>
        /// 说明
        /// </summary>
        public string Remark { get; set; }

        /// <summary>
        /// 卡号
        /// </summary>
        public string CardNumber { get; set; }
       
        /// <summary>
        /// 手机号
        /// </summary>
        public string Mobile { get; set; }

        public string TypeName
        {
            get
            {
                switch (Type)
                {
                    case RechargeType_Enum.IssueCard:
                        return "办卡";
                    case RechargeType_Enum.Recharge:
                        return "充值";
                    case RechargeType_Enum.Consumption:
                        return "扣费";

                }
                return "";
            }
        }

    }
}
